package com.bos.data.repositories.jpa;

import com.bos.data.model.BosUserModel;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;

/**
 * create by luojie 2018/6/1
 */
public interface UserJPARepository extends JpaRepository<BosUserModel, Integer>, JpaSpecificationExecutor<BosUserModel> {
    @Modifying
    @Query("update BosUserModel set password=?2 where id=?1")
    int updatePass(int uid,String newPass);
}
